﻿

function DrawPie(data, id) {

    var option = ECharts.ChartOptionTemplates.Pie(data);
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option);
    ECharts.Charts.RenderChart(opt);

}
function DrawPie2(data, id) {

    var option = ECharts.ChartOptionTemplates.Pie2(data);
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option);
    ECharts.Charts.RenderChart(opt);
   

}
function radar(data, id) {

    var option = ECharts.ChartOptionTemplates.radar(data);
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option);
    ECharts.Charts.RenderChart(opt);

}
function DrawBar(data, id) {

    var option = ECharts.ChartOptionTemplates.Bars(data);
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option);
    ECharts.Charts.RenderChart(opt);

}
function Drawline(data, id) {

    var option = ECharts.ChartOptionTemplates.lines_HS(data);
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option);
    ECharts.Charts.RenderChart(opt);

}
function Drawline2(data, id) {

    var option = ECharts.ChartOptionTemplates.lines_YZ(data);
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option);
    ECharts.Charts.RenderChart(opt);

}
function Drawmap(dt, id) {

    var option = ECharts.ChartOptionTemplates.Map_AS(dt);
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option); 
    ECharts.Charts.RenderChart(opt); 
}

//--add test
function DrawPie3(data, id) {

    var option = ECharts.ChartOptionTemplates.Pie3(data);
   
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option);
    ECharts.Charts.RenderChart(opt);

}
//内蒙九断线
function DrawlineNM( id) {

    var option = ECharts.ChartOptionTemplates.Lines_NM();
    var container = document.getElementById(id);
    opt = ECharts.ChartConfig(container, option);
    ECharts.Charts.RenderChart(opt);

}
